package com.cysion.study.ui.personal

import com.cysion.study.ktbox.base.BaseActivity
import com.cysion.study.ktbox.net.BaseResponseRx
import com.cysion.study.ktbox.net.ErrorHandler
import com.cysion.study.ktbox.utils.darkTextTheme
import com.cysion.other.color
import com.cysion.targetfun._subscribe
import com.cysion.study.uibox.dialog.Alert
import com.cysion.study.R
import com.cysion.study.customview.java.SimpleData
import com.cysion.study.helper.UserCache
import com.cysion.study.net.ApiClient
import com.cysion.study.widget.ShowToast
import kotlinx.android.synthetic.main.activity_black_list.*


//黑名单
class BlackListActivity : BaseActivity() {

    var simpleDatas: MutableList<SimpleData.Students> = mutableListOf()
    override fun getLayoutId(): Int = R.layout.activity_black_list
    private var caid=""
    override fun initView() {

        darkTextTheme(color(R.color.white))
        iv_back.setOnClickListener {
            finish()
        }





    }

    override fun initData() {
        super.initData()
//        getDataList()
    }

    private fun getDataList() {
        //isSign 是否签到 -1.全部 0.已签到 1.未签到
        ApiClient.api.classesGetByClid(UserCache.token,caid,"-1")
            .compose(BaseResponseRx.validateToMain())
            ._subscribe {
                _onNext {
                    Alert.close()


                }
                _onError {
                    Alert.close()
                    ShowToast(ErrorHandler.handle(it).errorMsg)
                }
            }
    }











    override fun closeMvp() {
    }


}
